home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
SGI Developer Toolbox 6.1
/
SGI Developer Toolbox 6.1 - Disc 4.iso
/
public
/
RTF
/
richtext_test.C
< prev
next >
Wrap
C/C++ Source or Header
|
1994-08-01
|
1KB
|
60 lines
/* main.c
*
* Test driver for RichText widget.
* supports:
* Wcl interface specification,
* Editres protocol
*
* USE:
* compile, link with libRichText.a
* setenv XENVIRONMENT test.res
* ./test
*/
#include <Xm/Xm.h>
extern "C" void MriRegisterMotif(XtAppContext);
#include "X11/Wc/WcCreate.h"
#include "RichText.h"
#include <stdio.h>
#include <stdlib.h>
extern void RegisterHelp (Widget, const char*);
/* X11R5 only */
extern "C" void _XEditResCheckMessages(Widget, XtPointer, XEvent *, Boolean *);
main(Cardinal argc, char *argv[])
{
XtAppContext app;
Widget appShell;
appShell = XtAppInitialize(&app, "RichTextTest",
NULL, 0,
&argc, argv, NULL,
(ArgList)NULL, 0);
MriRegisterMotif ( app );
WcRegisterClassName(app, "XcRichText", xcRichTextWidgetClass);
WcWidgetCreation ( appShell );
XtAddEventHandler(appShell,
(EventMask) 0,
TRUE,
_XEditResCheckMessages,
NULL);
XtRealizeWidget ( appShell );
XtAppMainLoop ( app );
return 0;
}